<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <button onclick="fn()">跳转2</button>
        
    <!-- 
         window.history.go(-1)
         返回页面 不刷新页面 
         获取不到最新数据    
     -->

    <script>
        console.log(document.referrer,'???');
        function fn(){
            // window.location.href = document.referrer;
            window.history.go(-1)
        }
        localStorage.setItem('ma','马英鹏1')
    </script>
</body>
</html>